import adminRoutes from './routes/adminRoutes.js'
import teacherRoutes from './routes/teacherRoutes.js'
import studentRoutes from './routes/studentRoutes.js'
import baseRoutes from './routes/baseRoutes.js'

export default [
  {
    path: '/',
    redirect: '/login',
    meta: {
      isPublic: true,
    }
  },
  {
    path: '/login',
    name: 'login',
    component: () => import('@/views/Login/LoginView.vue'),
    meta: {
      isPublic: true,
    }
  },
  {
    path: '/home',
    name: 'home',
    component: () => import('@/views/Home/HomeView.vue'),
    children: [...adminRoutes, ...teacherRoutes, ...studentRoutes, ...baseRoutes],
  },
  {
    path: '/:arg(.*)*',
    redirect: '/login',
    meta: {
      isPublic: true,
    },
  },
]
